
package com.market.web.action;

import java.util.List;

import com.market.bean.Message;
import com.market.web.form.MessageForm;
import com.market.web.utils.ListUtils;

public class MsgListAction extends MessageAction
{
    public String execute() throws Exception
    {
        List news = getMessageService().findNews(10);
        List know = getMessageService().findKnow(10);
        List setCategory = setCategory(ListUtils.convert(news, Message.class, MessageForm.class));
        getRequest().setAttribute("news", setCategory);
        getRequest().setAttribute("know", setCategory(ListUtils.convert(know, Message.class, MessageForm.class)));
        return SUCCESS;
        //return mapping.findForward("msg");
    }
}
